package com.yingjie.mobileguard.activities;

import android.app.Activity;
import android.content.pm.PackageInfo;
import android.content.pm.PackageManager;
import android.content.pm.PackageManager.NameNotFoundException;
import android.os.Bundle;
import android.widget.TextView;

import com.yingjie.phoneSafe.R;

public class SplashActivity extends Activity {
	private TextView tv_splash_version;
	
	//�������
	private PackageManager packManager;
	/**
	 * splashչ�ֲ�Ʒlogo
	 * ��ʼ��Ӧ�ó���
	 * ���汾����
	 * Ӧ�ó���Ϸ���
	 */
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_splash);
		tv_splash_version=(TextView) findViewById(R.id.tv_splash_version);
		//�õ����а�   
		packManager=getPackageManager();
		//Ĭ��д0 
		try {
			PackageInfo packageinfo=packManager.getPackageInfo(getPackageName(), 0);
			String version=packageinfo.versionName;
			tv_splash_version.setText(tv_splash_version.getText()+version);
		} catch (NameNotFoundException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		
		
	}

	
}
